<?php
/**
 * User: tridungpham
 * Date: 3/30/11
 * Time: 9:06 AM
 */
 
class LoginController extends Controller
{
    function __construct()
    {
        $this->loadLibrary('Utility');
        $this->loadLibrary('Session');
    }

    function index()
    {
        $this->loadView('login_form');
        $this->views['login_form']->setBlockData("Đăng nhập để sử dụng hệ thống",'main_header');
        $this->views['login_form']->setBlock('block_content',NULL,FALSE);
        $this->views['login_form']->render();
    }

    function submit()
    {
        $this->loadModel('login');
        $this->models['login']->handleSubmit();
    }
}